import antfu from '@antfu/eslint-config';

export default antfu({
  formatters: {
    css: true,
    html: true,
    markdown: 'prettier',
  },
  stylistic: {
    semi: true,
  },
  rules: {},
  regexp: false,
  unocss: true,
  typescript: {
    overrides: {
      'ts/no-unused-expressions': 'off',
    },
  },
  vue: {
    overrides: {
      'vue/component-name-in-template-casing': ['error', 'PascalCase', {
        registeredComponentsOnly: false,
        ignores: ['/^swiper/', '/\\./'],
      }],
      'vue/prop-name-casing': ['error', 'camelCase'],
      'vue/attribute-hyphenation': ['error', 'never', {
        ignore: [],
      }],
      'vue/custom-event-name-casing': ['error', 'camelCase'],
      'vue/v-on-event-hyphenation': ['error', 'never', {
        autofix: true,
        ignore: [],
      }],
    },
  },
});
